<?php

namespace App\Models;

use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Database\Eloquent\SoftDeletes;

class User extends Authenticatable
{
    public $table = 'users';

    /**
     * The attributes that are mass assignable.
     *
     * @var array
     */
    protected $fillable = [
        'name',
        'username',
        'api_token',
        'type',
        'password',
        'sex',
        'school_id'
    ];

    public function logs(){
        $this->hasMany(Log::class,'user_id','id');
    }
}
